<!-- Teacher_SelectClassPicker.html -->
<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0"/>
		<meta name="format-detection" content="telephone=no, email=no, date=no, address=no">
		<title>选择班级弹出窗</title>
		<link rel="stylesheet" type="text/css" href="../../css/mui.min.css">
		<link rel="stylesheet" type="text/css" href="../../css/mui.picker.min.css">
		<style type="text/css">
			html,body{
				background-color: rgba(0,0,0,0);
			}
			.mui-poppicker-btn-cancel{
				display: none;
			}
		</style>
	</head>
	<body onclick="onHideClick()">
	</body>
	<script type="text/javascript" src="../../script/api.js"></script>
	<script type="text/javascript" src="../../script/mui.min.js"></script>
	<script type="text/javascript" src="../../script/mui.picker.min.js"></script>
	<script type="text/javascript">
		var classPicker;
		(function($, doc){
			$.init();
			$.ready(function() {
				classPicker = new $.PopPicker();	
			});
		})(mui, document);
		apiready = function(){
		    setTimeout(function(){
		    	showPickerClick();
		    }, 500);
		}
		function showPickerClick(){
			classPicker.setData(api.pageParam.classArr);
			classPicker.show(function(items) {
				var classData = items[0];
				api.sendEvent({
				    name: 'selectTrainClassNotifi',
				    extra: {
				        id: classData.id, 
				        classname: classData.classname
				    }
				});
				// api.setFrameAttr({
				//     name: 'Teacher_SelectClassPicker',
				//     hidden: true
				// });
				api.closeFrame({
				    name: 'Teacher_SelectClassPicker'
				});
			});
		}
		function onHideClick(){
			// api.setFrameAttr({
			//     name: 'Teacher_SelectClassPicker',
			//     hidden: true
			// });
			api.closeFrame({
			    name: 'Teacher_SelectClassPicker'
			});
		}
	</script>
</html>